package eclipse.lib.graphics;
/**
 * The GLColor class represents an ARGB/RGB color.
 */
public class GLColor
{
	private float A;
	private float R;
	private float G;
	private float B;
	/**
	 * Creates an ARGB from specified color values
	 * @param a Alpha value
	 * @param r Red value
	 * @param g Green value
	 * @param b Blue value
	 */
	public GLColor(float a, float r, float g, float b)
	{
		ARGB(a, r, g, b);
	}
	/**
	 * Creates a RGB from specified color values
	 * @param r Red value 
	 * @param g Green value
	 * @param b Blue value
	 */
	public GLColor(float r, float g, float b)
	{
		RGB(r, g, b);
	}
	/**
	 * Creates an ARGB color
	 * @param a Alpha value
	 * @param r Red value
	 * @param g Green value
	 * @param b Blue value
	 */
	public void ARGB(float a, float r, float g, float b)
	{
		this.A = a;
		this.B = b;
		this.G = g;
		this.R = r;
	}
	/**
	 * Creates a RGB color
	 * @param r Red value
	 * @param g Green value
	 * @param b Blue value
	 */
	public void RGB(float r, float g, float b)
	{
		this.A = 1.0f;
		this.B = b;
		this.G = g;
		this.R = r;
	}
	/** Returns the alpha value for the color */
	public float getAlpha()
	{
		return A;
	}
	/** Returns the red value for the color */
	public float getRed()
	{
		return R;
	}
	/** Returns the blue value for the color */
	public float getBlue()
	{
		return B;
	}
	/** Returns the green value for the color */
	public float getGreen()
	{
		return G;
	}
	/**
	 * Sets the alpha value
	 * @param a Alpha value
	 */
	public void setAlpha(float a)
	{
		this.A = a;
	}
	/**
	 * Sets the red value
	 * @param r Red value
	 */
	public void setRed(float r)
	{
		this.R = r;
	}
	/**
	 * Sets the green value
	 * @param g Green value
	 */
	public void setGreen(float g)
	{
		this.G = g;
	}
	/**
	 * Sets the blue value
	 * @param b blue value
	 */
	public void setBlue(float b)
	{
		this.B = b;
	}
}
